<template>
    <div class="video-background">
      <video autoplay loop muted>
        <source :src="videoSource" type="video/mp4">
      </video>
      <!-- 其他内容 -->
    </div>
  </template>
  
  <script>
  export default {
    data() {
      return {
        videoSource: '/assets/bg.mp4' // 将路径替换为你的视频文件路径
      };
    }
  };
  </script>
  
  <style>
  .video-background {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
  }
  
  .video-background video {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
  }
  </style>